import java.util.Scanner;

public class Answer1 {
    //添加逗号
    //https://www.nowcoder.com/practice/f51c317e745649c0900996fd3f683aed?tpId=290&tqId=39934&ru=/exam/oj
    public static void main(String[] args) throws Exception{

        Scanner in=new Scanner(System.in);
        String s=in.next();
        int n=s.length();

        for(int i=0;i<n;i++){
            System.out.print(s.charAt(i));

            if((n-i-1)%3 == 0 && i!=n-1){
                System.out.print(",");
            }
        }

    }
}
